﻿
#import <Foundation/Foundation.h>
#import <UIKit/UIKit.h>
#import "cocos2d.h"

#import "BaseScene.h"
#import "RamUnit.h"
#import "BaseLayer.h"
@implementation BaseScene

@synthesize _layers;

-(id)init{
	self=[super init];
	if(self!=nil){
		_layers=[[NSMutableArray alloc] init];
	}
	return self;
}

-(void)addLayerDirector:(BaseLayer*)_layer{ 
	if(_layers!=nil){
		[_layers addObject:_layer];
	}
	RamLog(@"BaseScene.addLayerDirector.layers count:%i",[_layers count]);
}

-(void)zoom:(float)_scale{
	for(BaseLayer *_per in _layers){
		if([_per getIsZoomByScene]==TRUE){
			_per.scale=_scale;
		}
	}
	
}

-(void)dealloc{
	[_layers release];
	[super dealloc];
}
@end
